<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <p></p>
    <script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>

    <script>
        axios({
            url: 'http://hmajax.itheima.net/api/city',
            params:{
                pname: '河北省'
            }
        }).then(
            res => {
                console.log(res.data.list);
                document.querySelector('p').innerHTML = res.data.list.join('<br>')
            }
        )
    </script>
</body>
</html>